<script setup lang="ts">
import { defineEmits, } from 'vue'
import zhCn from "element-plus/lib/locale/lang/zh-cn";
const props = defineProps({
    //子组件接收父组件传递过来的值

    total: {
        type: Number,
        default: 0
    },
    pageCount: {
        type: Number,
        default: ''
    },

})
const emit = defineEmits(['current-change'])
const handleCurrentChange = (val: number) => {
    emit('current-change', val)
}
</script>

<template>
    <el-config-provider :locale="zhCn">
        <el-pagination layout="prev, pager, next,total,jumper" :total="props.total" @current-change="handleCurrentChange"
             background :page-count="props.pageCount" :hide-on-single-page="true"/>
    </el-config-provider>
</template>
<style>

</style>

